import React, { Component } from 'react'
import { Result, Button } from 'antd';
import { withRouter } from 'react-router-dom'

@withRouter
class NotFound extends Component {
  goBackHome = () => {
    this.props.history.push('/')
  }
  render() {
    return (
      <Result
        status="404"
        title="404"
        subTitle="Sorry, the page you visited does not exist."
        extra={<Button onClick={this.goBackHome} type="primary">Back Home</Button>}
      />
    )
  }
}

export default NotFound
